package com.dly.hope.repository;

import com.dly.hope.modle.FriendGroup;
import org.springframework.data.jpa.repository.JpaRepository;

import java.util.List;
import java.util.Optional;

public interface FriendGroupRepository extends JpaRepository<FriendGroup, String> {

    Optional<FriendGroup> findTopByNameAndCreateUserAndDataStatus(String name, String userId, Integer dataStatus);

    Optional<FriendGroup> findByIdAndDataStatus(String Id, Integer dataStatus);

    List<FriendGroup> findAllByCreateUserAndDataStatus(String userId, Integer dataStatus);
}
